package com.itheima.mapper;

import com.itheima.pojo.Account;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface AccountMapper {
    @Select("select * from tbl_account where id = #{id}")
    public Account getById(Integer id);

    @Insert("insert into tbl_account values (null,#{name},#{money})")
    void addAccount(Account account);

    @Select("select * from tbl_account")
    List<Account> findAll();
}
